<template>
	<view>
		<uni-head title="理赔详情"></uni-head>
		<view style="height: 1px; background-color: #EEEEEE;"></view>
		<view style="background-color: #fff;">
			<view class="statusbox">
				<view class="info">预审已通过，请邮寄材料</view>
				<view class="understand">理赔需要什么材料>></view>
			</view>
		</view>
		<view style="background-color: #fff;">
			<view class="dizhibox flex-space-between">
				<view class="flex">
					<view class="icnobox">收</view>
					<view class="congst">
						<view class="topbox flex">
							<view class="left">张先生</view>
							<view class="right">1517393478</view>
						</view>
						<view class="bottom">
							安徽省合肥市瑶海区佳山路123号太平洋保险有限公司
						</view>
					</view>
				</view>
				<view class="fuzhi" @click="fuzhiclick">
					<image  src="../../static/Icon/fz.png" mode=""></image>
					<view >复制</view>
				</view>
			</view>
		</view>
		<view style="background-color: #fff;margin-top: 20upx;">
			<view class="inpbox">
				<view class="inp flex">
					<view class="name">快递公司</view>
					<input type="text" value="" placeholder="请输入快递公司" v-model="logistics"  placeholder-style="font-size: 28upx;color:#BBBBBB"/>
				</view>
				<view class="inp flex">
					<view class="name">快递单号</view>
					<input type="text" value="" placeholder="请输入快递单号" v-model="logistics_no" placeholder-style="font-size: 28upx;color:#BBBBBB"/>
				</view>
			</view>
		</view>
		<view class="butbox" @click="yjiclick">
			确认邮寄
		</view>
	</view>
</template>

<script>
	import uniHead from "@/components/uni-dead/head.vue";
	import {setClipboardData,navTo,showToast} from '../../utils/method.js'
	export default {
		components: { uniHead },
		data() {
			return {
				id:'',
				logistics:"",
				logistics_no:'',
			}
		},
		onLoad(id) {
			this.id=id.id
		},
		methods: {
			// 点击复制
			fuzhiclick(){
				setClipboardData()
			},
			// 确认邮寄
			yjiclick(){
				if(this.logistics==''||this.logistics_no==''){
					showToast('请填写物流信息')
				}else{
					this.ajax('report/mailDo',{
						data:{
							id:this.id,
							logistics:this.logistics,
							logistics_no:this.logistics_no,
						},
						success:(res)=>{
								navTo('/pages/order/yjrecord?id='+this.id)
							// if(res.code==1){
							// 	navTo('/pages/order/yjrecord?id='+this.id)
							// }else{
							// 	showToast(res.msg)
							// }
						}
					})
				}
				
			}
		}
	}
</script>

<style lang="less" scoped>
.statusbox{
	margin:0 24upx;
	overflow: hidden;
	.info{
		margin-top: 56upx;
		font-size: 36upx;
		color: #000000;
		font-weight: bold;
	}
	.understand{
		font-size: 28upx;
		color: #5280F8;
		margin: 50upx 0;
	}
}
.dizhibox{
	margin:20upx 24upx 0;
	// overflow: hidden;
	.icnobox{
		margin-bottom: 96upx;
		width: 52upx;
		height: 52upx;
		line-height: 52upx;
		text-align: center;
		font-size: 28upx;
		color: #fff;
		border-radius: 50%;
		background-color: #6FBA2C;
	}
	.congst{
		padding: 50upx 0;
		margin-left: 14upx;
		width: 520upx;
		.topbox{
			color: #000000;
			font-size: 28upx;
			.left{
				
			}
		}
		.bottom{
			margin-top: 18upx;
			color: #999999;
			font-size: 28upx;
		}
	}
	.fuzhi{
		// width: 70upx;
		image{
			width: 32upx;
			height: 32upx;
			margin-left: 8upx;
		}
		view{
			font-size: 26upx;
			color: #777777;
			text-align: center;
		}
	}
}
.inpbox{
	
	margin: 0upx 24upx ;
	.inp{
		padding: 20upx 0;
	}
	.name{
		font-size: 28upx;
		color: #000000;
		margin-right: 18upx;
	}
	input{
		width: 540upx;
		height: 84upx;
		font-size: 28upx;
		border-radius: 10upx;
		padding-left: 20upx;
		border: 1px solid #EEEEEE;
	}
}
.butbox{
	// margin-top: 152upx;
	font-size: 32upx;
	color: #fff;
	height: 100upx;
	line-height: 100upx;
	text-align: center;
background: linear-gradient(180deg, #4EB4FE 0%, #5280F8 100%);
	margin: 152upx 24upx 40upx;
	border-radius: 10upx;
}
</style>
